PBSetVol
You can change the default volume and default directory using thePBSetVol
function.
FUNCTION PBSetVol (paramBlock: ParmBlkPtr; async: Boolean): OSErr;
paramBlock
- A pointer to a basic File Manager parameter block.
async
- A Boolean value that specifies asynchronous (
TRUE
) or synchronous (FALSE
) execution.
--> ioCompletion
ProcPtr
A pointer to a completion routine. <-- ioResult
OSErr
The result code of the function. --> ioNamePtr
StringPtr
A pointer to a pathname. --> ioVRefNum
Integer
A volume reference number or a working directory reference number. DESCRIPTION
If you pass a volume reference number inioVRefNum
, thePBSetVol
function makes the specified volume the default volume and the root directory of that volume the default directory. If you pass a working directory reference number,PBSetVol
makes the specified directory the default directory, and the volume containing that directory
the default volume.ASSEMBLY-LANGUAGE INFORMATION
The trap macro forPBSetVol
is_SetVol
.RESULT CODES
noErr 0 No error nsvErr -35 No such volume bdNamErr -37 Bad volume name paramErr -50 No default volume